package org.xx.armory.swing.builders;

import static org.apache.commons.lang3.StringUtils.trimToEmpty;

public class CheckBoxModelBuilder
        extends ComponentModelBuilder<CheckBoxModel> {
    private String text;
    private String forName;

    public CheckBoxModelBuilder() {
    }

    public CheckBoxModelBuilder setText(
            String text
    ) {
        this.text = text;
        return this;
    }

    /**
     * {@inheritDoc}
     */
    @Override
    public CheckBoxModel build() {
        return new CheckBoxModel(getLineInfo(), getName(), isVisible(), trimToEmpty(this.text));
    }
}
